package com.tech.comsumer_mall.controller;

import com.tech.service.business.BusinessService;
import io.swagger.annotations.Api;
import org.apache.dubbo.config.annotation.DubboReference;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author litianlin
 * @date 2023/11/30 10:32
 * @description:
 */
@Api(tags = "分布式id")
@RestController
@RequestMapping("distributeId")
public class BusinessController {
    @DubboReference
    private BusinessService service;


    @RequestMapping("purchase")
    public String dbDistributeId() {
        service.purchase("U100001", "C00321", 2);
        return "OK";
    }

}
